# Maintainer: Maarten van Gompel <proycon@anaproy.nl>
pkgname=libtar
pkgver=1.2.20
pkgrel=0
pkgdesc="library for manipulating tar files from within C programs"
arch="all"
url="https://github.com/mdippery/libtar"
license="NCSA"
makedepends="libtool autoconf automake autoconf-archive zlib-dev"
subpackages="$pkgname-dev $pkgname-doc"
source="$pkgname-$pkgver.tar.gz::https://github.com/tklauser/libtar/archive/refs/tags/v$pkgver.tar.gz"
options="!check"

prepare() {
	default_prepare
	autoreconf -fi
}

build() {
	./configure \
		--build=$CBUILD \
		--host=$CHOST \
		--prefix=/usr \
		--sysconfdir=/etc \
		--localstatedir=/var
	make
}

package() {
	make DESTDIR="$pkgdir" install
}

sha512sums="11a12695abf4f9668801d24b7b552daed1219b2f395c09818d15e16721f7136d63aa0c09e442401e4fedbf7335748f0dc46f8da21b94b36595910b2fe44d4aea  libtar-1.2.20.tar.gz"
